import { defineStore } from "pinia";
import { ref } from "vue";
export const useAuthorizationStore = defineStore(
  "authorization",
  () => {
    const authorization = ref("");

    const setAuthorization = (newAuthorization) => {
      authorization.value = newAuthorization;
    };

    const removeAuthorization = () => {
      authorization.value = "";
    };

    return {
      authorization,
      setAuthorization,
      removeAuthorization,
    };
  },
  { persist: true }
);
